from models import db, BaseModel


class {{table.tableHumpName}}(BaseModel):
    """
    {{table.comment}}模型
    """
    __tablename__ = "{{table.tableName}}"
    __table_args__ = ({"comment": "{{table.comment}}"}){% for column in table.columns %}{%if column.name not in ['id','create_time','update_time','is_deleted', 'create_user', 'update_user']%}
    {{column.camelName}} = db.Column(db.{{column.type}}{%if column.hasLength%}({% if column.length is not none%}{{column.length}}{%endif%}){%endif%}, name="{{column.name}}", unique={% if column.unique is not none%}True{% else %}False{%endif%}, nullable={% if column.nullable is not none%}True{% else %}False{%endif%}, comment="{{column.comment}}"){%endif%}{% endfor %}

